package com.zhuj.handler;

import com.alibaba.fastjson.JSONObject;
import com.zhuj.client.NrpcClient;
import com.zhuj.core.entity.ServerResponse;
import io.netty.channel.ChannelHandlerContext;
import io.netty.channel.SimpleChannelInboundHandler;

/**
 * Created by Administrator on 2018/1/3.
 */
public class ClientHandler extends SimpleChannelInboundHandler<ServerResponse> {

    protected void channelRead0(ChannelHandlerContext ctx, ServerResponse response) throws Exception {
        if (response != null){
            NrpcClient.processRunnable.produce(response);
        }
    }
}
